import { getReports } from '@/api/reports'

export default {
  namespaced: true,
  state: {
    // 数据报表
    reports: {}
  },
  mutations: {
    setReportsObj (state, data) {
      state.reports = data
    }
  },
  actions: {
    async getReportsObj (context) {
      const res = await getReports()
      // console.log(res.data)
      context.commit('setReportsObj', res.data)
    }
  }
}
